package com.dangdang.action.authorize;

import com.dangdang.action.BaseAction;
import com.dangdang.service.AuthorizeService;
import com.dangdang.service.ServiceFactory;

/**
 * 
 * @author Wangpeihu
 * @team [Never give up]
 * @since JDK1.6(建议)
 * @date 2010-1-25
 */
public class VerifyAction extends BaseAction {
	private String code;

	private final AuthorizeService us = ServiceFactory.getAuthorizeService();

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String execute() {
		boolean b = us.verifyUser(code);
		if (b) {
			return "success";
		} else {
			return "input";
		}
	}
}
